home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / std / c++ / 859 < prev    next >
Encoding:
Text File  |  1996-08-06  |  2.3 KB  |  54 lines

  1. Path: engnews1.Eng.Sun.COM!taumet!clamage
  2. From: James Kanze US/ESC 60/3/141 #40763 <kanze@lts.sel.alcatel.de>
  3. Newsgroups: comp.std.c++
  4. Subject: Re: Placement delete suggestion Keywords: delete placement
  5. Date: 26 Mar 1996 16:23:05 GMT
  6. Organization: ?
  7. Approved: clamage@eng.sun.com (comp.std.c++)
  8. Message-ID: <9603261124.AA22276@lts.sel.alcatel.de>
  9. References: <4j4ec5$d41@fsgi01.fnal.gov>
  10. NNTP-Posting-Host: taumet.eng.sun.com
  11. In-Reply-To: b91926@fsgi01.fnal.gov's message of 25 Mar 1996 10:05:32 PST
  12. Content-Length: 1397
  13. X-Lines: 31
  14. Originator: clamage@taumet
  15.  
  16. In article <4j4ec5$d41@fsgi01.fnal.gov> b91926@fsgi01.fnal.gov (David
  17. Sachs) writes:
  18.  
  19. |> The lack of a placement delete expression form, corresponding to
  20. |> the placment new form, has been a topic for serious discussion in
  21. |> this group.  The obvious problem with placement delete is that
  22. |> any non-awkward form could be ambiguous, though examples that
  23. |> would show such ambguity are probably infrequent.
  24.  
  25. |> In view of this, it might be reasonable if the standards committee
  26. |> bit the bullet and declare that such ambiguous forms should be
  27. |> treated as placement deletes. That should be anything of the form:
  28.  
  29. |> delete leftparenthesis expressionlist rightparenthesis expression
  30.  
  31. |> delete[] leftparenthesis expressionlist rightparenthesis expression
  32.  
  33. |> Admitedly, this would probably break some existing code, but the
  34. |> broken expressions can be fixed by adding parentheses.
  35.  
  36. Is the expression: delete (*pf)( p ) placement delete or not?  (The
  37. variable pf has type `T* (*)( T* )', and p type T*.)  If not, why not?
  38. If so, how can I remove the ambiguity (by adding parentheses or
  39. otherwise)?
  40.  
  41. --
  42. James Kanze         Tel.: (+33) 88 14 49 00        email: kanze@gabi-soft.fr
  43. GABI Software, Sarl., 8 rue des Francs-Bourgeois, F-67000 Strasbourg, France
  44. Conseils, Θtudes et rΘalisations en logiciel orientΘ objet --
  45.                 -- A la recherche d'une activitΘ dans une region francophone
  46.  
  47.  
  48.  
  49. [ comp.std.c++ is moderated.  To submit articles: try just posting with      ]
  50. [ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu         ]
  51. [ FAQ:      http://reality.sgi.com/employees/austern_mti/std-c++/faq.html    ]
  52. [ Policy:   http://reality.sgi.com/employees/austern_mti/std-c++/policy.html ]
  53. [ Comments? mailto:std-c++-request@ncar.ucar.edu                             ]
  54.